import request from '@/utils/request'

// 创建用户签到
export function createSignIn(data) {
  return request({
    url: '/member/sign-in/create',
    method: 'post',
    data: data
  })
}

// 更新用户签到
export function updateSignIn(data) {
  return request({
    url: '/member/sign-in/update',
    method: 'put',
    data: data
  })
}

// 删除用户签到
export function deleteSignIn(id) {
  return request({
    url: '/member/sign-in/delete?id=' + id,
    method: 'delete'
  })
}

// 获得用户签到
export function getSignIn(id) {
  return request({
    url: '/member/sign-in/get?id=' + id,
    method: 'get'
  })
}

// 获得用户签到分页
export function getSignInPage(query) {
  return request({
    url: '/member/sign-in/page',
    method: 'get',
    params: query
  })
}

// 导出用户签到 Excel
export function exportSignInExcel(query) {
  return request({
    url: '/member/sign-in/export-excel',
    method: 'get',
    params: query,
    responseType: 'blob'
  })
}
